﻿//////////////////////////////////////////////////////////////////////////////
//
//  Copyright © 1998-2024 Glodon Company Limited.  All rights reserved.
//
//  Use of this software is subject to the terms of the Glodon license
//  agreement provided at the time of installation or download, or which
//  otherwise accompanies this software in either electronic or hard copy form.  
//
//////////////////////////////////////////////////////////////////////////////

#pragma once
#include "GcmpModelInterface.h"
#include "IObject.h"
#include "GbmpTypeDefs.h"
#include "NdbDataSchema.h"

namespace gcmp
{
    /// \brief 数据集版本状态
    SERIALIZABLE_ENUM_CLASS(DatasetVersionStatus)
    {
        WorkInProgress, /// < 正在进行
        Published,      /// < 已发布
    };

    /// \brief 数据集版本
    /// \see IDataset
    class GCMP_MODEL_INTERFACE_EXPORT IDatasetVersion: public IObject
    {
        DEFINE_CAST_DERIVED(gcmp::IDatasetVersion, gcmp::IObject)

    public:
        /// \brief 获取版本Id
        /// \return int 版本Id
        virtual int GetId() const = 0;

        /// \brief 获取版本号
        /// \return int 版本号。合法的版本号>=0
        virtual int GetDatasetVersion() const = 0;

        /// \brief 获取数据集的Id
        /// \return std::wstring 数据集Id
        virtual std::wstring GetDatasetId() const = 0;

        /// \brief 获取版本状态
        /// \return DatasetVersionStatus 版本状态
        virtual DatasetVersionStatus GetDatasetVersionStatus() const = 0;

        /// \brief 析构函数
        virtual ~IDatasetVersion();
    };
}

